#include "Shrink_Static_lyvm.h"
#include<assert.h>
#include<set>

//using namespace Ogre;

void Shrink_Static_lyvm::algorithm(){
	vector<DIVA_VM* > vms = _area->getAllVMs();
	vector<DIVA_VM* >::iterator itr;
	DIVA_VM* p;
	Ogre::Vector3 iniPosition;
	bool bFirst = true;

	for(itr=vms.begin(); itr!=vms.end(); itr++){
		p = (*itr);
		if(bFirst) {
			iniPosition = p->getPosition();
			bFirst = false;
			continue;
		}
		p->setPosition(iniPosition.x, iniPosition.y, iniPosition.z);	
	}
}